<!--<?php
print <<<EOT
-->

<script src="css/edit.js"></script>
<script>
<!--

function validate(form) {
    var id_ary = $js_id_ary_str;
    for (var i=0; i<id_ary.length; i++) {
        if (document.all('cart_qty['+id_ary[i]+']').value>document.all('inventory_qty['+id_ary[i]+']').value) {
            //alert('Your input number \''+document.all('cart_qty['+id_ary[i]+']').value+'\' ');
            alert('The number you enter \''+document.all('cart_qty['+id_ary[i]+']').value+'\' is more than the available quantity.');
            return false;
        }
    }

    return ture;
}


function oSubmit() {
    if (form1.o_name.value == "") {
        alert("Please enter Name.");
		form1.o_name.focus();
		return false;
    }
    if (form1.o_city.value == "") {
        alert("Please enter City.");
		form1.o_city.focus();
		return false;
    }
    if (form1.o_phone.value == "") {
        alert("Please enter Telephone.");
		form1.o_phone.focus();
		return false;
    }
    form1.action = "cart_submit.php";
    form1.submit();
    
}


//-->
</script>

        <tr>
          <td background="./images/colour/jf_colour_gold_100.gif" width="1"><img src="./images/spacer.gif" width="1" height="1" alt=""></td>
          <td bgcolor="FFFFFF" width="10"><img src="./images/spacer.gif" width="10" height="1" alt=""></td>
          <td bgcolor="FFFFFF" width="720" align="left" valign="top"><div><img name="" src="./images/spacer.gif" width="720" height="10" alt=""></div>
            <table width="720" border="0" cellspacing="0" cellpadding="0">
              <tr>
                <td width="150" background="./images/nav/jf_nav_main_bkgd.gif" align="left" valign="top"><table width="150" border="0" cellspacing="0" cellpadding="0">
                    <tr>
                      <td><a href="index.php"><img src="./images/nav/jf_nav_logo.gif" width="150" height="210" alt="jans2en furniture" border="0"></a></td>
                    </tr>

<!--
EOT;
foreach ($LEFT_MENU_ARY as $k=>$v) { 
print <<<EOT
--> 

					<tr>
                      <td><a href="{$v['url']}" onMouseOver="MM_swapImage('jf_nav_menu_$k','','./images/nav/{$v['pic']}-over.gif',1)" onMouseOut="MM_swapImgRestore()"><img src="./images/nav/{$v['pic']}.gif" alt="{$v['name']}" name="jf_nav_menu_$k" width="150" height="20" id="jf_nav_menu_$k" border="0"></a></td>
                    </tr>

<!--
EOT;
} 
print <<<EOT
--> 

                  </table></td>
                <td background="./images/colour/jf_colour_navy_100.gif" width="1"><img name="" src="./images/spacer.gif" width="1" height="1" alt=""></td>
                <td width="568" align="left" valign="top" background="./images/colour/jf_colour_navy_07.gif"><table width="568" border="0" cellspacing="0" cellpadding="0">
                    <tr>
                      <td background="./images/colour/jf_colour_navy_100.gif" height="1"><img name="" src="./images/spacer.gif" width="1" height="1" alt=""></td>
                    </tr>
                    <tr>
                      <td bgcolor="FFFFFF" align="left" valign="middle" class="breadcrumb" height="14">&nbsp;<a href='index.php'>Home</a>&gt;<span class='breadcrumbActive'>Basket</span> </td>
                    </tr>
                  </table>
                  <div><img src="./images/section_header/jf_section_header_cart.jpg" alt="Container" name="jf_section_header_placer" width="568" height="95" id="jf_section_header_placer"></div>
                  <div><img name="" src="./images/spacer.gif" width="568" height="4" alt=""></div>
                  <div><img name="" src="./images/spacer.gif" width="568" height="4" alt=""></div>
                  
                  <table width="568" border="0" cellspacing="0" cellpadding="0">
                    <tr>
                      <td width="5"><img name="" src="./images/spacer.gif" width="5" height="5" alt=""></td>
                      <td bgcolor="FFFFFF" width="10"><img name="" src="./images/spacer.gif" width="10" height="10" alt=""></td>
                      <td bgcolor="FFFFFF" width="538"><img name="" src="./images/spacer.gif" width="538" height="10" alt=""></td>
                      <td bgcolor="FFFFFF" width="10"><img name="" src="./images/spacer.gif" width="10" height="10" alt=""></td>
                      <td width="1" align="left" valign="top" background="./images/colour/jf_colour_navy_15.gif"><img name="" src="./images/colour/jf_colour_navy_07.gif" width="1" height="1" alt=""></td>
                      <td width="4"><img name="" src="./images/spacer.gif" width="4" height="4" alt=""></td>
                    </tr>
                    <tr>
                      <td width="5"><img name="" src="./images/spacer.gif" width="5" height="5" alt=""></td>
                      <td bgcolor="FFFFFF" width="10"><img name="" src="./images/spacer.gif" width="10" height="245" alt=""></td>
                      <td bgcolor="FFFFFF" width="538" class="text" align="left" valign="top">
                        
                        

<!--
EOT;
if (count($info_ary) == 0) {
print <<<EOT
--> 			        	
					   <div class="titles">Sorry Your Basket is Empty!</div>
					   Please browse through the various product sections and add the desired items to your cart with the 'Add to basket' button on the product detail page.


<!--
EOT;
} else {
print <<<EOT
--> 

			        	<form action="cart_view.php" method="post" name="form1"  onSubmit="return validate(this)">
			        	<input type="hidden" name="act" value="change">
			    		<table width="538" border="0" cellspacing="0" cellpadding="0" align="center">
			    		
			    		<tr><td colspan=10>
        			      <!--table width="100%" border="0" cellspacing="0" cellpadding="0">        			    	
        			        <tr><td align="right" width="64"><strong>Customer</strong> :</td><td align="left" >&nbsp;{$user_info_ary['firstname']} {$user_info_ary['lastname']}</td></tr>
			    		    <tr><td align="right" width="64"><strong>City</strong> :</td><td align="left" >&nbsp;{$user_info_ary['city']}</td></tr>
			    		    <tr><td align="right" width="64"><strong>Country</strong> :</td><td align="left" >&nbsp;{$COUNTRY_ARY[$user_info_ary['countryid']]}</td></tr>
			    		  </table-->
			    		</td></tr>			    		        			    		
			    		
			    		<tr><td colspan=10 height=5></td></tr>	
			    		<tr><td colspan=10 bgcolor="#000000" height=1></td></tr>															
						<tr class="cartAlternatingRowB">
			    			<td align="center" valign="middle" class="cartHeading" width="45"></td>
			    			<td align="left" ></td>
			    			<td align="left" valign="middle" class="cartHeading" width="60">Item No.</td>
			    			<td align="left" valign="middle" class="cartHeading" width="148">Description</td>
			    			
			    			<td align="right" valign="middle" class="cartHeading" width="50">CBM</td>
			    			<td align="right" valign="middle" class="cartHeading" width="42">CUFT</td>
			    			
			    			<td align="right" valign="middle" class="cartHeading" width="55">Price<br>{$money_type}</td>
			    			<td align="right" valign="middle" class="cartHeading" width="55">QTY</td>
			    			<td align="right" valign="middle" class="cartHeading" width="60">Total<br>{$money_type}</td>
			    			<td align="right" valign="middle" class="cartHeading" width="60" height="30">Remove</td>
						</tr>
						<tr><td colspan=10 bgcolor="#A5AAB0" height=1></td></tr>
						
						<tr><td colspan=10 bgcolor="#FFFFFF" height=4></td></tr>
			
<!--
EOT;
foreach ($index_ary as $v) {    
	$v['price']  = number_format($v['price'], 2, '.', ',');
	$v['cost']   = number_format($v['cost'], 2, '.', ',');
	$v['cbm']    = number_format($v['cbm'], 3, '.', ',');
	$v['cuft']   = number_format($v['cuft'], 3, '.', ',');	
		
print <<<EOT
-->
			            <tr class="cartAlternatingRowB1" height=45>
			    			<td align="center" valign="top" width="45"><a href="product_details.php?pid={$v['pid']}"><img src="./attachments/{$v['small_pic']}" border="0" class="picture" width="40" height="40"></a></td>
			    			<td align="left" width="8"></td>
			    			<td align="left" valign="middle" width="60">{$v['code']}</td>
			    			<td align="left" valign="top" width="148" class="cartmiddle"><span class="cartmiddle2">{$v['name']}</span></td>
			    			
			    			<td align="right" valign="middle" width="50">{$v['cbm']}</td>
			    			<td align="right" valign="middle" width="42">{$v['cuft']}</td>
			    			
			    			<td align="right" valign="middle" width="55">{$v['price']} </td>
			    			<td align="right" valign="middle" width="55"><input type="text" name="cart_qty[{$v['old_k']}]" value="{$v['count']}" size="3"></td>
			    			{$v['js_str']}
			    			<td align="right" valign="middle" width="60">{$v['cost']}</td>
			    			<td align="center" valign="middle" width="60" height="30">
			    			<a onclick="return confirm('Do you really want to remove {$v['name']} from your cart?')" href="cart_view.php?act=delone&pid={$v['intype']}_{$v['pid']}"  onmouseover="jf_button_remove_{$v['pid']}.src='./images/button/bt_delete.gif'" onmouseout="jf_button_remove_{$v['pid']}.src='./images/button/bt_delete.gif'" ><img src="./images/button/bt_delete.gif" alt="Remove This Item From Your Cart" name="jf_button_remove_01" width="26" height="14" border="0" id="jf_button_remove_{$v['pid']}"></a>
			    			</td>
						</tr>

<!--
EOT;
} 

print <<<EOT
--> 
						<tr><td colspan=10 bgcolor="#A5AAB0" height=1></td></tr>
						
						
						
						<tr>
						    <td colspan=4 height=25 align="right"><strong>Total&nbsp;</strong> :</td>
			    			
			    			<td align="right" valign="middle"><div class="kk">{$total_cbm} </div></td>
			    			<td align="right" valign="middle"><div class="kk">&nbsp;{$total_cuft} </div></td>
			    			<td align="right" valign="middle"></td>
			    			<td align="right" valign="middle"><div class="kk">{$total_qty2} </div></td>
			    			
			    			
			    			
			    			<td colspan=1 align="right"><div class="kk">$total_cost </div></td>
						    <td colspan=1 align="right"></td>
			    			
						
						
						  <!--td colspan=8 height=25 align="right"><strong>Total:  </strong> </td>
						  <td colspan=1 align="right">$total_cost</td>
						  <td colspan=1 align="right"></td-->
						</tr>
						
						
						<tr><td colspan=10 height=10 align="right" valign="middle">
						
						<tr>
						  <td colspan=2>Name:</td>
						  <td colspan=8><input type=text name=o_name></td>
						</tr>
						<tr>
						  <td colspan=2>City:</td>
						  <td colspan=8><input type=text name=o_city></td>
						</tr>
						<tr>
						  <td colspan=2>Telephone:</td>
						  <td colspan=8><input type=text name=o_phone></td>
						</tr>
						<tr>
						  <td colspan=10>For verification purposes only</td>
						</tr>
						
						
						
						
						
						<tr><td colspan=10 bgcolor="#000000" height=1></td></tr>
						<tr><td colspan=10 height=28 align="right" valign="middle">
						
                              
						
						<a href="javascript:;" onClick="MM_openBrWindow('printer.php?page=cart_view','printerfriendly','scrollbars=yes,width=600,height=500')" onMouseOver="MM_swapImage('jf_button_printer_friendly','','./images/button/jf_button_print-over.gif',1)" onMouseOut="MM_swapImgRestore()">
                        <img src="./images/button/jf_button_print.gif" alt="Printer Friendly" name="jf_button_printer_friendly" width="90" height="20" border="0"  align="absmiddle" id="jf_button_printer_friendly">
                        </a>
						
                        <input type="image" onMouseOver="MM_swapImage('cart_update','','./images/button/jf_button_update_quantities-over.gif',1)" onMouseOut="MM_swapImgRestore()" src="./images/button/jf_button_update_quantities.gif" alt="Update" name="cart_update" width="130" height="20" border="0" id="cart_update" align="absmiddle">
						
                        
						<!--A onmouseover="cart_checkout.src='./images/button/jf_button_submit_order-over.gif'" onmouseout="cart_checkout.src='./images/button/jf_button_submit_order.gif'" href="cart_submit.php"-->
						<A onmouseover="cart_checkout.src='./images/button/jf_button_submit_order-over.gif'" onmouseout="cart_checkout.src='./images/button/jf_button_submit_order.gif'" onclick="oSubmit()">
						<IMG id="cart_checkout" alt="Checkout" src="./images/button/jf_button_submit_order.gif" width=90 border=0 align="absmiddle">
						</A>
						
						</td></tr>
						</table></form>
						
<!--
EOT;
}
print <<<EOT
--> 
                      
                      </td>
                      <td bgcolor="FFFFFF" width="10"><img name="" src="./images/spacer.gif" width="10" height="245" alt=""></td>
                      <td width="1" align="left" valign="top" background="./images/colour/jf_colour_navy_15.gif"><img name="" src="./images/colour/jf_colour_navy_07.gif" width="1" height="1" alt=""></td>
                      <td width="4"><img name="" src="./images/spacer.gif" width="4" height="4" alt=""></td>
                    </tr>

<!--
EOT;
if (count($info_ary) > 0) {
print <<<EOT
-->                    
                    
                    <tr>
                      <td width="5"><img name="" src="./images/spacer.gif" width="5" height="5" alt=""></td>
                      <td bgcolor="FFFFFF" width="2"><img name="" src="./images/spacer.gif" width="2" height="5" alt=""></td>
                      <td bgcolor="FFFFFF" colspan=1><strong>Attention:</strong> Submit Order will empty the basket. <br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;If you are not yet finished with your order, please just <a href="javascript:;" onClick="MM_openBrWindow('printer.php?page=cart_view','printerfriendly','scrollbars=yes,width=600,height=500')" onMouseOver="MM_swapImage('jf_button_printer_friendly','','./images/button/jf_button_print-over.gif',1)" onMouseOut="MM_swapImgRestore()">Print</a> the list.</td>
                      <td bgcolor="FFFFFF" width="2"><img name="" src="./images/spacer.gif" width="2" height="5" alt=""></td>
                      <td width="1" align="left" valign="top" background="./images/colour/jf_colour_navy_15.gif"><img name="" src="./images/colour/jf_colour_navy_07.gif" width="1" height="1" alt=""></td>
                      <td width="4"><img name="" src="./images/spacer.gif" width="4" height="4" alt=""></td>
                    </tr>
                    
<!--
EOT;
}
print <<<EOT
--> 
                   
                    <tr>
                      <td width="5"><img name="" src="./images/spacer.gif" width="5" height="5" alt=""></td>
                      <td bgcolor="FFFFFF" width="10"><img name="" src="./images/spacer.gif" width="10" height="10" alt=""></td>
                      <td bgcolor="FFFFFF" width="538"><img name="" src="./images/spacer.gif" width="538" height="10" alt=""></td>
                      <td bgcolor="FFFFFF" width="10"><img name="" src="./images/spacer.gif" width="10" height="10" alt=""></td>
                      <td width="1" align="left" valign="top" background="./images/colour/jf_colour_navy_15.gif"><img name="" src="./images/colour/jf_colour_navy_07.gif" width="1" height="1" alt=""></td>
                      <td width="4"><img name="" src="./images/spacer.gif" width="4" height="4" alt=""></td>
                    </tr>
                    
                    <tr>
                      <td width="5"><img name="" src="./images/spacer.gif" width="5" height="1" alt=""></td>
                      <td width="10" align="left" valign="top" background="./images/colour/jf_colour_navy_15.gif"><img name="" src="./images/colour/jf_colour_navy_07.gif" width="1" height="1" alt=""></td>
                      <td background="./images/colour/jf_colour_navy_15.gif" width="538"><img name="" src="./images/spacer.gif" width="538" height="1" alt=""></td>
                      <td background="./images/colour/jf_colour_navy_15.gif" width="10"><img name="" src="./images/spacer.gif" width="10" height="1" alt=""></td>
                      <td width="1" align="left" valign="top" background="./images/colour/jf_colour_navy_15.gif"><img name="" src="./images/colour/jf_colour_navy_15.gif" width="1" height="1" alt=""></td>
                      <td width="4"><img name="" src="./images/spacer.gif" width="4" height="1" alt=""></td>
                    </tr>
                    
                   </table>   
                  
                  <div><img name="" src="./images/spacer.gif" width="568" height="4" alt=""></div>
                  
                  <div><img name="" src="./images/spacer.gif" width="10" height="2" alt=""></div></td>
                <td background="./images/colour/jf_colour_navy_100.gif" width="1"><img name="" src="./images/spacer.gif" width="1" height="1" alt=""></td>
              </tr>
              
              <tr>
                <td background="./images/nav/jf_nav_main_bkgd.gif" wid><img name="" src="./images/spacer.gif" width="150" height="20" alt=""></td>
                <td background="./images/colour/jf_colour_navy_100.gif" width="1"><img name="" src="./images/spacer.gif" width="1" height="1" alt=""></td>
                <td><table width="568" border="0" cellspacing="0" cellpadding="0">
                    <tr>
                      <td background="./images/colour/jf_colour_navy_100.gif" height="1"><img name="" src="./images/spacer.gif" width="1" height="1" alt=""></td>
                      <td background="./images/colour/jf_colour_navy_100.gif" height="1"><img name="" src="./images/spacer.gif" width="1" height="1" alt=""></td>
                    </tr>
                    <tr>
                      <td align="left" valign="middle" height="18"><a href="javascript:history.back(1)" onMouseOver="MM_swapImage('jf_button_return_to_wishlist','','./images/button/jf_button_back_to_previous-over.gif',1)" onMouseOut="MM_swapImgRestore()"><img src="./images/button/jf_button_back_to_previous.gif" alt="" name="jf_button_return_to_wishlist" width="128" height="13" border="0" id="jf_button_return_to_wishlist"></a></td>
                      <td align="right" valign="middle" height="18"><a href="#top" onMouseOver="MM_swapImage('jf_button_back_to_top','','./images/button/jf_button_back_to_top-over.gif',1)" onMouseOut="MM_swapImgRestore()"><img src="./images/button/jf_button_back_to_top.gif" alt="Back to top" name="jf_button_back_to_top" width="70" height="13" border="0" id="jf_button_back_to_top"></a></td>
                    </tr>
                    <tr>
                      <td background="./images/colour/jf_colour_navy_100.gif" height="1"><img name="" src="./images/spacer.gif" width="1" height="1" alt=""></td>
                      <td background="./images/colour/jf_colour_navy_100.gif" height="1"><img name="" src="./images/spacer.gif" width="1" height="1" alt=""></td>
                    </tr>
                  </table></td>
                <td background="./images/colour/jf_colour_navy_100.gif" width="1"><img name="" src="./images/spacer.gif" width="1" height="1" alt=""></td>
              </tr>
            </table>
            <div><img name="" src="./images/spacer.gif" width="720" height="10" alt=""></div></td>
          <td bgcolor="FFFFFF" width="10"><img src="./images/spacer.gif" width="10" height="10" alt=""></td>
          <td background="./images/colour/jf_colour_gold_100.gif" width="1"><img src="./images/spacer.gif" width="1" height="1" alt=""></td>
        </tr>
        
<!--
EOT;
?>-->